package com.msb.order.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @program: microservices
 * @ClassName TestController
 * @description:
 * @author: slfang
 * @create: 2024-01-02 18:36
 * @Version 1.0
 **/
@RestController
public class TestController {

    @GetMapping("/test/aa")
    public String aa(){
        return "aa";
    }

    @GetMapping("/test/bb")
    public String bb(){
        return "bb";
    }

    //com.msb.controller.DegradationRuleController#slowRequestRatio
    @RequestMapping("/slowRequestRatio")
    public String slowRequestRatio(){
        try {
            Thread.sleep(200);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        return "熔断降级==慢调用比例";
    }
}
